﻿@model LiteBlog.Models.PostCollectionModel
@{
    this.ViewBag.Title = "Posts by Tag - " + Model.FilterName;
}

<html>
<head>
    <title>@ViewBag.Title</title>
    <meta name="viewport" content="width=device-width, initial-scale=1">
    @if (Model.NextPageAvailable)
    {
        <link rel="next" href="@Model.NextPageUrl" />
    }
    <style>
        img {
            width: 100%;
        }

        pre {
            width: 100%;
            white-space: pre-wrap;
        }
    </style>

</head>
<body>
    <h1>Tag : @Model.FilterName</h1>
    @foreach (var post in Model.PostCollection)
    {
        <h2>
            <a href="@Url.Action("Index", "Post", new { id = post.FileID })">
                @post.Title
            </a>
        </h2>
        <div>@Html.Raw(post.HighlightedContents)</div>
    }
</body>
</html>
